package jvm.string;

public class TestStringAdd {
    public static void main(String[] args) {
        String s1="hello";
        String s2="world";
        System.out.println(s1+s2=="helloworld");//new StringBuilder.append()创建对象到堆区
        final String s3="hello";
        final String s4="world";
        System.out.println(s3+s4=="helloworld");//创建到常量池
    }
}
